package com.unisedu.pay.enumration;

public enum WebSite{

    ACTIVITY("冬令营",7,"activity");


    private String name;
    private int index;
    private String prefix;

    private WebSite(String name, int index, String prefix){
        this.name = name;
        this.index = index;
        this.prefix = prefix;
    }

    public static WebSite getInstance(String prefix){
        for (WebSite ws : WebSite.values()) {
            if (ws.getPrefix().equals(prefix)) {
                return ws;
            }
        }
        return null;
    }

    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    public int getIndex() {
        return index;
    }
    public void setIndex(int index) {
        this.index = index;
    }

    public String getPrefix() {
        return prefix;
    }

    public void setPrefix(String prefix) {
        this.prefix = prefix;
    }
}
